<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org"
      xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head th:include="layout :: htmlhead" th:with="title='用户管理'">

</head>
<body class="layui-layout-body">

<div class="layui-layout layui-layout-admin">
    <!--头-->
    <div th:replace="fragments/head :: header"></div>

    <div class="layui-body" style="margin: 1%">
        <blockquote class="layui-elem-quote">成员管理列表</blockquote>
        <table id="memberList" lay-filter="memberTable"></table>

        <script type="text/html" id="optBar">
            <a class="layui-btn layui-btn-xs" lay-event="edit">编辑</a>
            <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="del">删除</a>
        </script>
    </div>


    <!--编辑-->
    <div id="setMember" class="layer_self_wrap" style="width:500px;display:none;">
        <form id="memberForm" class="layui-form layui-form-pane" method="post" action=""
              style="margin-top: 20px; margin-left: 20px;">
            <input id="pageNum" type="hidden" name="pageNum"/>
            <input id="id" type="hidden" name="menberId"/>
            <div class="layui-form-item">
                <label class="layui-form-label">成员姓名</label>
                <div class="layui-input-inline">
                    <input type="text" name="memberName" lay-verify="memberName" id="memberName"
                           placeholder="请输入成员姓名" autocomplete="off" class="layui-input" style="width: 250px">
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">成员职位</label>
                <div class="layui-input-inline">
                    <input type="text" name="memberPosition" lay-verify="memberPosition" id="memberPosition"
                           placeholder="请输入成员职位" autocomplete="off" class="layui-input" style="width: 250px">
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-upload">
                    <button type="button" class="layui-btn" id="memberImg">上传照片</button>
                    <div class="layui-upload-list">
                        <img class="layui-upload-img" id="demoMember"
                             style="width: 92px; height: 92px; margin: 0 10px 10px 0;">
                        <p id="demoText"></p>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-input-block" style="margin-left: 10px;">
                    <button class="layui-btn"  lay-submit="" lay-filter="teamSubmit">提交</button>
                    <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                </div>
            </div>
        </form>
    </div>

    <!--添加-->
    <div id="addMember" class="layer_self_wrap" style="width:500px;display:none;">
        <form id="teamForm" class="layui-form layui-form-pane" method="post" action=""
              style="margin-top: 20px; margin-left: 20px;">
            <div class="layui-form-item">
                <label class="layui-form-label">成员姓名</label>
                <div class="layui-input-inline">
                    <input type="text" name="memberName" lay-verify="memberName" id="Name"
                           placeholder="请输入成员姓名" autocomplete="off" class="layui-input" style="width: 250px">
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">成员职位</label>
                <div class="layui-input-inline">
                    <input type="text" name="memberPosition" lay-verify="memberPosition" id="Position"
                           placeholder="请输入成员职位" autocomplete="off" class="layui-input" style="width: 250px">
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-upload">
                    <button type="button" class="layui-btn" id="Img">上传照片</button>
                    <div class="layui-upload-list">
                        <img class="layui-upload-img" id="MemberPhoto"
                             style="width: 92px; height: 92px; margin: 0 10px 10px 0;">
                        <p id="memberText"></p>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-input-block" style="margin-left: 10px;">
                    <button class="layui-btn"  lay-submit="" lay-filter="memberSubmit">提交</button>
                    <button type="reset" class="layui-btn layui-btn-primary">重置</button>
                </div>
            </div>
        </form>
    </div>
    <!--底部-->
    <div th:replace="fragments/footer :: footer"></div>
    <script src="/js/dateUtils.js"></script>
    <script src="/js/manage/teamManage.js"></script>
    <!--layui.table图片显示不全，需重新定义CSS  -->
    <style type="text/css">
        .layui-table-cell {
            height: auto !important;
            white-space: normal;
        }
    </style>

</div>
</body>
</html>